# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:        Young  
# Name:         hmwk2
# Description:
# Author:       asus
# Date:         2019/3/5
#-------------------------------------------------------------------------------


#编写一个python程序，从控制台输入一个整数（大于0），然后利用format方法生成一个星号塔
s = input("请输入星号塔的层数：")
high = int(s)
i = high
while i > 0:
    print("{:<{a}}{:*>{b}}".format(" ", "", a=i, b=((2 * high) - 1) - ((i-1) * 2)))
    i = i-1